<template>
  <el-table-column v-bind="column">
    <template slot="header" v-if="column.showTip">
      {{ column.label }}
      <el-tooltip class="item" effect="dark" :content="column.tipContent" placement="top">
        <i class="el-icon-question"></i>
      </el-tooltip>
    </template>
    <!-- 默认插槽 -->
    <template v-if="column.render" #default="scope">
      <ColumnRender :scope="scope" :render="column.render" />
    </template>
  </el-table-column>
</template>

<script>
import ColumnRender from './column-render'

export default {
  name: 'BaseColumn',
  components: {
    ColumnRender,
  },
  props: {
    column: {
      type: Object,
      default: () => ({}),
    },
  },
}
</script>
